﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Data;

namespace QLTTAN.DAL
{
    public class BaoCaoDAL
    {
        ConnectionData conn;

        public DataTable BaoCao_LoadBaoCaoGhiDanh(DateTime ngay)
        {
            conn = new ConnectionData();

            int Nparameter = 1;
            string[] name = new string[Nparameter];
            object[] value = new object[Nparameter];

            name[0] = "MaKhoaHoc";
            value[0] = ngay;

            return conn.GetData("BAOCAOGHIDANH_LOAD", name, value, Nparameter);
        }

        public DataTable BaoCao_LoadBaoCaoKeToan(DateTime thang)
        {
            conn = new ConnectionData();

            int Nparameter = 1;
            string[] name = new string[Nparameter];
            object[] value = new object[Nparameter];

            name[0] = "Thang";
            value[0] = thang;

            return conn.GetData("BAOCAOKETOAN_LOAD", name, value, Nparameter);
        }

        public DataTable BaoCao_LoadBaoCaoHocVu(int makhoa)
        {
            conn = new ConnectionData();

            int Nparameter = 1;
            string[] name = new string[Nparameter];
            object[] value = new object[Nparameter];

            name[0] = "MaKhoa";
            value[0] = makhoa;


            return conn.GetData("BAOCAOHOCVU_LOAD", name, value, Nparameter);
        }
    }
}
